package com.zzhou.common.library.util;

import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.Locale;

/**
 * <desc>
 * Created by The Moss on 2018/8/10.
 */

public class FormatUtils {

    public static final SimpleDateFormat FORMAT_YYYYMMDDHHMMSS = new SimpleDateFormat(
            "yyyyMMddHHmmss", Locale.CHINA);

    public static String formatNow(SimpleDateFormat format) {
        if (format == null)
            format = FORMAT_YYYYMMDDHHMMSS;
        return format.format(new Date());
    }
}
